#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QCamera>
#include <QCameraInfo>
#include <QCameraViewfinder>
#include <QCameraImageCapture>

#include "pollthread.h"

namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    explicit MainWindow(QWidget *parent = 0);
    ~MainWindow();

private slots:
    void displayImage(int, QImage image);
    void camCapture();
    void sensorPoll();

private:
    Ui::MainWindow *ui;
    QCamera *cam;
    QCameraImageCapture *cap;
    QList<QCameraInfo> camInfoList;
    QImage curImage;
    int camError;
    PollThread *pollTask;
};

#endif // MAINWINDOW_H
